Skip to content

Conversation

@dingfeli
Copy link
Contributor

@dingfeli dingfeli commented May 12, 2025

Issue #, if available:
#1466

Description of changes:
Enables background server load:

  • As described in Background server loading #1466, relegates tools/list to the same level as prompts, which are also fetched in the background.
  • Enables users to set timeout for servers init, beyond which the stragglers continue to load in the background, enabling users to start typing. This is done via q settings mcp.initTimeout. I have opted to not have this in mcp.json because this might conflict with how IDE interprets the config.
  • Enables users to interrupt server loading (even with timeout set) to immediately start conversation.
  • /tools now show servers still in loading.

Removal of mcp_client crate:

  • No longer needed since the refactor

Refinement of conversation invariant logic with regards to tool calls with incorrect names:
There are three scenarios in which intervention would be needed:

  1. The model had decided to call a tool with its partial name AND there is only one such tool, in
    which case we would automatically resolve this tool call to its correct name. This will NOT
    result in an error in its tool result. The intervention here is to substitute the partial name
    with its full name.
  2. The model had decided to call a tool with its partial name AND there are multiple tools it
    could be referring to, in which case we WILL return an error in the tool result. The
    intervention here is to substitute the ambiguous, partial name with a dummy.
  3. The model had decided to call a tool that does not exist. The intervention here is to
    substitute the non-existent tool name with a dummy.

List changed support for prompts and tools:

  • List changed support for prompts and tools.
  • This is added because it is enabled by background server load.

By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

@codecov-commenter
Copy link

codecov-commenter commented May 12, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Please upload report for BASE (main@aa146bf). Learn more about missing BASE report.
Report is 39 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #1775   +/-   ##
=======================================
  Coverage        ?   16.75%           
=======================================
  Files           ?      213           
  Lines           ?    20704           
  Branches        ?      871           
=======================================
  Hits            ?     3468           
  Misses          ?    17236           
  Partials        ?        0           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

brandonskiser
brandonskiser previously approved these changes May 12, 2025
@dingfeli dingfeli dismissed chaynabors’s stale review May 13, 2025 18:21

Change requested implemented

@dingfeli dingfeli merged commit ec6fa9c into main May 13, 2025
21 checks passed
@dingfeli dingfeli deleted the background-server-load branch May 13, 2025 18:22
This was referenced May 14, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants